import java.awt.*;
/*
若想比较对象属性值是否相同,在Object类的equals不能满足
需要重写equals()
 */

public class ObjectDemo {
    public static void main(String[] args) {
        Point p=new Point(100,200);
        Point p1=new Point(100,200);
        System.out.println(p==p1);
        System.out.println(p.equals(p1));
    }
}
